﻿@using IntroMongo.Models
@model User
@{
    ViewBag.Title = "Remarks";
}
<h2>
    Remarks for @Model.GetFullName()</h2>
<table cellpadding="0" cellspacing="0">
    <tr>
        <td>
            Remark
        </td>
        <td>
            Date
        </td>
    </tr>
    @foreach (Remark remarkItem in Model.Remarks)
    {
        <tr>
            <td>
                @remarkItem.RemarkContent
            </td>
            <td>
                @remarkItem.Date
            </td>
        </tr>
    }
</table>
<h2>
    New remark
</h2>
@using (Html.BeginForm())
{
    <table cellpadding="0" cellspacing="0">
        <tr>
            <td>
                Remark
            </td>
            <td>
                <textarea name="newRemark" cols="30" rows="5"></textarea>
            </td>
        </tr>
    </table>
    <input type="submit" value="Save remark" />
}